﻿using Oplug.EntityFramework;
using Oplug.EntityFramework.RossLive;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Oplug.Services
{
    public class PowerService : IDisposable
    {
        public OplugLiveDbContext dbContext;
        public IRepository<RossPowers, int> repository;
        public IRepository<FormMethods, int> formMethods;
        public PowerService(string nameOrConnectionString)
        {
            dbContext = new OplugLiveDbContext(nameOrConnectionString);
            repository = new Repository<RossPowers, int>(dbContext);
            formMethods = new Repository<FormMethods, int>(dbContext);
        }
        public void Dispose()
        {
            dbContext.Dispose();
        }
    }
}
